<?php 
namespace app\gptcms\model;
use think\facade\Db;
use think\facade\Session;

class MediaModel 
{
	/**
	 * 获取 云存储配置
	 * @param $wid 账户id
	 * @return 
	 */
 	static public function storageInfo($wid){
 		$user = Db::table("kt_base_user")->where(["id"=>$wid])->find();
		$res = Db::table('kt_base_storage_config')->where('uid',$user["agid"])->find();
		return $res;
	}

	/**
	 * 获取 云存储配置
	 * @return 
	 */
 	static public function storageInfoByUid($uid){
		$res = Db::table('kt_base_storage_config')->where('uid',$uid)->find();
		return $res;
	}

}
